package com.lzy.api.controller.user;

import com.lzy.grace.result.GraceJSONResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Date;

@Api(value = "用户管理相关接口定义",tags = {"用户管理相关接口定义功能的controller"})
@RequestMapping("appUser")
public interface AppUserMngControllerApi {

    @ApiOperation(value = "获取用户信息列表",notes = "获取用户信息列表",httpMethod = "POST")
    @PostMapping("/queryAll")
    public GraceJSONResult queryAll(@RequestParam String nickname,
                                    @RequestParam Integer status,
                                    @RequestParam Date startDate,
                                    @RequestParam Date endDate,
                                    @ApiParam(name = "page", value = "查询下一页的第几页", required = false)
                                        @RequestParam Integer page,
                                    @ApiParam(name = "pageSize", value = "分页的每一页显示的条数", required = false)
                                        @RequestParam Integer pageSize
                                    );


    @PostMapping("/userDetail")
    @ApiOperation(value = "查看用户详情信息", notes = "查看用户详情信息", httpMethod = "POST")
    public GraceJSONResult userDetail(@RequestParam String userId);


    @PostMapping("/freezeUserOrNot")
    @ApiOperation(value = "冻结用户，或解除封号", notes = "冻结用户，或解除封号", httpMethod = "POST")
    public GraceJSONResult freezeUserOrNot(@RequestParam String userId, @RequestParam Integer doStatus);




}
